www.gusucode.com > 良精ASP微博管理系统 V1.0 > 良精ASP微博管理系统 V1.0\code\admin\admin_login.asp
<!--#include file="../Include/liangconn.asp"--> <!--#include file="../Include/Function.asp"--> <!--#include file="../Include/Md5.asp"--> <% if Request("act") = "loginchk" then username = Wodig.Checkin(trim(Request.form("username"))) password = Wodig.Checkin(replace(trim(Request.Form("password")),"'","''")) Md5_Pass = md5(password) EwSys_CheckCode = replace(trim(Request("idcode")),"'","") if EwSys_CheckCode <> CStr(session("CheckCode")) then Response.write"<script>alert(""验证码不正确,请刷新后重新登陆 "&Copyright&" "");location.href=""Admin_Login.asp"";</script>" Response.end else set rs=server.createobject("adodb.recordset") sql="select * from Liangjing_Admin where Admin_LoginName='"&username&"'and Admin_Pass='"&Md5_Pass&"'" rs.open sql,conn,1,3 if not rs.EOF then rs("Admin_LoginNum") = rs("Admin_LoginNum") + 1 rs("Admin_LastLoginDate") = now() rs("Admin_LastLoginIP") = Request.ServerVariables("REMOTE_ADDR") rs.Update Session("_AdminID") = Rs("Admin_id") Session.Timeout = 1200 'Session("_Admin_isTxt") = Rs("Admin_isTxt") 'Session("_Admin_isMember") = Rs("Admin_isMember") 'Session("_Admin_isOnlineBy")= Rs("Admin_isOnlineBy") 'Session("_Admin_isMedia") = Rs("Admin_isMedia") 'Session("_Admin_isConfig") = Rs("Admin_isConfig") Response.Redirect ("Admin.asp") else Call Wodig.Msgbox2("用户不存在或用户名和密码不对应!",0,"Admin_Login.asp") Response.End() end if end if elseif Request("act") = "logout" then Session("_AdminID") = "" Session("_Admin_isTxt") = "" Session("_Admin_isMember") = "" Session("_Admin_isOnlineBy")= "" Session("_Admin_isMedia") = "" Session("_Admin_isConfig") = "" Response.Redirect("Admin_Login.asp") end if %> <html> <head> <title>管理员登录</title> <meta http-equiv="Content-Type" content="text/html; charset=gb2312"> <style type="text/css"> <!-- BODY { FONT-FAMILY: "宋体"; FONT-SIZE: 9pt; text-decoration: none; line-height: 150%; background-color: #FBFDFF; FONT-SIZE: 9pt;background:#ffffff; text-decoration: none; SCROLLBAR-FACE-COLOR: #C6EBDE; SCROLLBAR-HIGHLIGHT-COLOR: #ffffff; SCROLLBAR-SHADOW-COLOR: #39867B; SCROLLBAR-3DLIGHT-COLOR: #39867B; SCROLLBAR-ARROW-COLOR: #330000; SCROLLBAR-TRACK-COLOR: #E2F3F1; SCROLLBAR-DARKSHADOW-COLOR: #ffffff; } TD{ FONT-FAMILY: "宋体"; FONT-SIZE: 9pt;} Input{ FONT-SIZE: 9pt; HEIGHT: 20px;} Button{ FONT-SIZE: 9pt; HEIGHT: 20px; } Select{ FONT-SIZE: 9pt; HEIGHT: 20px;} A{ TEXT-DECORATION: none; color: #000000;} A:hover{ COLOR: #428EFF; text-decoration: underline;} .title{ background:url(Images/topBar_bg.gif);} .border{ border: 1px solid #39867B;} .tdbg{ background:#E1F4EE; line-height: 120%;} .topbg{ background:url(Images/topbg.gif); color: #FFFFFF;} .bgcolor { background-color: #91BCE3;} --> </style> <script language=javascript> <!-- function CheckBrowser() { var app=navigator.appName; var verStr=navigator.appVersion; if (app.indexOf('Netscape') != -1) { alert("良精科技友情提示:\n 你使用的是Netscape浏览器,可能会导致无法使用后台的部分功能。建议您使用 IE6.0 或以上版本。"); } else if (app.indexOf('Microsoft') != -1) { if (verStr.indexOf("MSIE 3.0")!=-1 || verStr.indexOf("MSIE 4.0") != -1 || verStr.indexOf("MSIE 5.0") != -1 || verStr.indexOf("MSIE 5.1") != -1) alert("良精科技友情提示:\n 您的浏览器版本太低,可能会导致无法使用后台的部分功能。建议您使用 IE6.0 或以上版本。"); } } //--> </script> </head> <body class="bgcolor"> <p> </p> <center> <table border=1 borderColor=#6699CC cellPadding=4 cellSpacing=1 width=450 style="border-collapse: collapse" align=center > <tr valign="baseline"> <td align="right" background=image/b1.gif> <div align="center"><font color="#000000" style="font-size: 10.5pt;"> <strong>良精软件科技 企业公司网站-微博管理系统</strong></font></div> </td> </tr> <tr valign="baseline"> <td bgcolor=#EFF1F3 align=center valign=middle height=60> <table width="100%" border="0" cellspacing="0" cellpadding="0"> <tr> <td width=20> </td> <td width=150> <div align="center"><img src="Images/admin_p.gif" width="90" height="100" border="0" usemap="#Map"> </div> </td> <td width=280> <form action="Admin_Login.asp" method="post" name="AdminLogin" id="AdminLogin" onSubmit="return CheckAdminLogin()"> <table width="100%" border="0" cellspacing="8" cellpadding="0" align="center"> <tr align="center"> <td height="38" colspan="2"><font color="#000000" size="3"><strong>管理员登录</strong></font> </td> </tr> <tr> <td align="right"><font color="#000000">用户名称:</font></td> <td><input name="username" style="width:160px;border-style:solid;border-width:1;padding-left:4;padding-right:4;padding-top:1;padding-bottom:1" onMouseOver="this.style.background='#FDE8FE';" onMouseOut="this.style.background='#FFFFFF'" onFocus="this.select(); "></td> </tr> <tr> <td align="right"><font color="#000000">用户密码:</font></td> <td><input name="password" type=password style="width:160px;border-style:solid;border-width:1;padding-left:4;padding-right:4;padding-top:1;padding-bottom:1" onMouseOver="this.style.background='#FDE8FE';" onMouseOut="this.style.background='#FFFFFF'" onFocus="this.select(); "></td> </tr> <tr> <td align="right"><font color="#00000">验 证 码:</font></td> <td><input style="border-style:solid;border-width:1;padding-left:4;padding-right:4;padding-top:1;padding-bottom:1" maxlength="6" size="8" name="idcode" onFocus="this.select();"> <font color="#FF0000">输入</font><a href="javascript:refreshimg()" title="看不清楚,换个图片。"><img id="checkcode" src="CheckCode/CheckCode.asp" style="border: 1px solid #ffffff" /></a></td> </tr> <tr> <td colspan="2"> <div align="center"> <input name="act" type="hidden" value="loginchk"> <input type="submit" name="Submit" value=" 确 认 " style="font-size: 9pt; height: 19; width: 60; color: #000000; background-color: #FFCCFF; border: 1 solid #336600" onMouseOver ="this.style.backgroundColor='#ffffff'" onMouseOut ="this.style.backgroundColor='#FFCCFF'"> <input name="reset" type="reset" id="reset" value=" 清 除 " style="font-size: 9pt; height: 19; width: 60; color: #000000; background-color: #FFCCFF; border: 1 solid #336600" onMouseOver ="this.style.backgroundColor='#ffffff'" onMouseOut ="this.style.backgroundColor='#FFCCFF'"><br> </div></td> </tr> </table> </form> </td> </tr> </table> </td> </tr> </table> <br> <a href="http://www.liangjing.net/"><font color="#990000"><b>良精软件科技有限公司</b></font></a> <a href="http://www.liangjing.net/"><font color="#990000"><b>Tel:010-81991660 QQ:65961930 </b></font></a> </center> <p align="center"> </p> <map name="Map"> <area shape="rect" coords="-15,33,108,68" href="http://www.liangjing.net/" target="_blank" alt="良精软件科技有限公司" title="良精软件科技有限公司"> </map> </body> </html>